CLS
RANDOMIZE TIMER
n = 3
m = 4
DIM b(n, m), c(n, m)
FOR i = 1 TO n
FOR j = 1 TO m
b(i, j) = FIX(RND * 62 - 36)
c(i, j) = b(i, j)
NEXT
NEXT
FOR i = 1 TO n
FOR j = 1 TO m
IF b(i, j) > 0 THEN c(i, j) = 0
NEXT
NEXT
PRINT "massiv 1"
FOR i = 1 TO n
FOR j = 1 TO m
PRINT b(i, j);
NEXT
PRINT
NEXT
PRINT "massiv 2"
FOR i = 1 TO n
FOR j = 1 TO m
PRINT c(i, j);
NEXT
PRINT
NEXT
Тестирование выполнено в программе QB64 ( Скачать )